package com.cq.hd.member.po;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;

import java.math.BigDecimal;
import java.time.LocalDateTime;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;

import com.cq.hd.common.serialize.Decimal2Serializer;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 商家经纪人分组表
 * </p>
 *
 * @author mYunYu
 * @since 2023-12-07
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("tb_business_group")
@ApiModel(value="TbBusinessGroupPo对象", description="商家经纪人分组表")
public class TbBusinessGroupPo implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "分组id")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "商家id")
    @TableField("business_id")
    private Long businessId;

    @ApiModelProperty(value = "经纪人id")
    @TableField("agent_id")
    private Long agentId;

    @ApiModelProperty(value = "分组名称")
    @TableField("group_name")
    private String groupName;

    @ApiModelProperty(value = "分组成员个数")
    @TableField("num")
    private Integer num;

    @ApiModelProperty(value = "默认分组状态：1-不是默认，2-是默认")
    @TableField("default_state")
    private Integer defaultState;

    @ApiModelProperty(value = "创建者")
    @TableField("create_by")
    private Integer createBy;

    @ApiModelProperty(value = "创建时间")
    @TableField("create_time")
    private LocalDateTime createTime;

    @ApiModelProperty(value = "更新者")
    @TableField("update_by")
    private Integer updateBy;

    @ApiModelProperty(value = "更新时间")
    @TableField("update_time")
    private LocalDateTime updateTime;

    @ApiModelProperty(value = "备注")
    @TableField("remark")
    private String remark;

    @ApiModelProperty(value = "删除状态:0-正常，1-已删除")
    @TableField("del_state")
    private Integer delState;

    @ApiModelProperty(value = "分组佣金")
    @JsonSerialize(using = Decimal2Serializer.class)
    private BigDecimal commissionRate;
}
